package org.jeecg.modules.oms.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import org.jeecg.common.aspect.annotation.Dict;
import org.springframework.format.annotation.DateTimeFormat;
import org.jeecgframework.poi.excel.annotation.Excel;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;

import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;

/**
 * 半成品销售订单明细表
 */
@Data
@TableName("oms_semi_product_sales_order_detail")
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@ApiModel(value = "SemiProductSalesOrderDetail对象", description = "半成品销售订单明细表")
public class SemiProductSalesOrderDetail implements Serializable {
    
    private static final long serialVersionUID = 1L;
    
    /**
     * 主键ID
     */
    @TableId(type = IdType.ASSIGN_ID)
    @ApiModelProperty(value = "主键ID")
    private String id;
    
    /**
     * 订单ID
     */
    @ApiModelProperty(value = "订单ID")
    private String orderId;
    
    /**
     * 物料ID
     */
    @ApiModelProperty(value = "物料ID")
    private String materialId;
    
    /**
     * 物料编码
     */
    @Excel(name = "物料编码", width = 15)
    @ApiModelProperty(value = "物料编码")
    private String materialCode;
    
    /**
     * 物料名称
     */
    @Excel(name = "物料名称", width = 20)
    @ApiModelProperty(value = "物料名称")
    private String materialName;
    
    /**
     * 物料类型
     */
    @Excel(name = "物料类型", width = 15, dicCode = "material_type")
    @Dict(dicCode = "material_type")
    @ApiModelProperty(value = "物料类型")
    private String materialType;
    
    /**
     * 规格型号
     */
    @Excel(name = "规格型号", width = 20)
    @ApiModelProperty(value = "规格型号")
    private String specification;
    
    /**
     * 单位
     */
    @Excel(name = "单位", width = 10)
    @ApiModelProperty(value = "单位")
    private String unit;
    
    /**
     * 数量
     */
    @Excel(name = "数量", width = 10)
    @ApiModelProperty(value = "数量")
    private Integer quantity;
    
    /**
     * 单价
     */
    @Excel(name = "单价", width = 15)
    @ApiModelProperty(value = "单价")
    private BigDecimal unitPrice;
    
    /**
     * 金额
     */
    @Excel(name = "金额", width = 15)
    @ApiModelProperty(value = "金额")
    private BigDecimal amount;
    
    /**
     * 成本
     */
    @Excel(name = "成本", width = 15)
    @ApiModelProperty(value = "成本")
    private BigDecimal unitCost;
    
    /**
     * 仓库ID
     */
    @ApiModelProperty(value = "仓库ID")
    private String warehouseId;
    
    /**
     * 仓库名称
     */
    @Excel(name = "仓库名称", width = 15)
    @ApiModelProperty(value = "仓库名称")
    private String warehouseName;
    
    /**
     * 备注
     */
    @Excel(name = "备注", width = 20)
    @ApiModelProperty(value = "备注")
    private String remark;
    
    /**
     * 创建人
     */
    @ApiModelProperty(value = "创建人")
    private String createBy;
    
    /**
     * 创建时间
     */
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @ApiModelProperty(value = "创建时间")
    private Date createTime;
    
    /**
     * 更新人
     */
    @ApiModelProperty(value = "更新人")
    private String updateBy;
    
    /**
     * 更新时间
     */
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @ApiModelProperty(value = "更新时间")
    private Date updateTime;
    
    /**
     * 租户ID
     */
    @ApiModelProperty(value = "租户ID")
    private Integer tenantId;
}
